package com.jvxb.manage.livable.entity;

import java.io.Serializable;

import com.fasterxml.jackson.annotation.JsonFormat;
import lombok.AllArgsConstructor;
import lombok.Data;
import io.swagger.annotations.ApiModelProperty;
import com.baomidou.mybatisplus.annotation.IdType;
import com.baomidou.mybatisplus.annotation.TableId;
import com.baomidou.mybatisplus.annotation.TableName;
import lombok.NoArgsConstructor;
import org.springframework.format.annotation.DateTimeFormat;

import java.util.Date;
/**
 * @author jvxb
 * @since 2022-02-15
 */
@Data
@TableName("db_monitor_data")
@NoArgsConstructor
@AllArgsConstructor
public class DbMonitorData implements Serializable {

    @TableId(value = "id", type = IdType.AUTO)
    private Integer id;
    @ApiModelProperty(value = "指标类型 MySQL，Redis，MongoDB，ES，Host...")
    private String moniObjType;
    @ApiModelProperty(value = "指标名")
    private String metricName;
    @ApiModelProperty(value = "监控对象标签")
    private String tag;
    @ApiModelProperty(value = "指标值")
    private String value;
    @ApiModelProperty(value = "创建时间")
    private Date createTime;

    public static final String ID = "id";

    public static final String MONI_OBJ_TYPE = "moni_obj_type";

    public static final String METRIC_NAME = "metric_name";

    public static final String TAG = "tag";

    public static final String VALUE = "value";

    public static final String CREATE_TIME = "create_time";

    public DbMonitorData(String moniObjType, String metricName, String tag, String value, Date createTime) {
        this.moniObjType = moniObjType;
        this.metricName = metricName;
        this.tag = tag;
        this.value = value;
        this.createTime = createTime;
    }


}
